package com.example.demo.controller;

import com.example.demo.service.RestClientService;
import jakarta.annotation.Resource;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RequestMapping("demo")
@RestController
public class RestClientController {
    @Resource
    private RestClientService restClientService;

    @GetMapping("say/{content}")
    public String sayHi(@PathVariable String content) {
        return restClientService.sayHello(content);
    }


    @GetMapping("say1/{content}")
    public String say1(@PathVariable String content) {
        return "Lisa say " + content;
    }



}
